import http from '@/libs/httpRequest'

// 直播获取成员列表
export const getLiveList = params => {
  return http({
    url: http.adornUrl('userbarrage/getuserNames'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 学习辅助教学辅助初始化表格数据

// 学习辅助教学辅助初始化及查询后表格数据
export const getDataList = params => {
  return http({
    url: http.adornUrl('studentNotes/queryStudentNotes'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 学习辅助教学辅助日志添加
export const addStudentNotes = params => {
  return http({
    url: http.adornUrl('studentNotes/addStudentNotes'),
    method: 'post',
    data: http.adornData(params)
  })
}
//查询课堂笔记
export const getStudentNote = params => {
  return http({
    url: http.adornUrl('studentNotes/getStudentNote'),
    method: 'post',
    data: http.adornData(params)
  })
}


// 学习辅助日志修改
export const updateStudentNotes = params => {
  return http({
    url: http.adornUrl('studentNotes/updateStudentNotes'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 教学辅助日志修改
export const updateTeacherNotes = params => {
  return http({
    url: http.adornUrl('teachingJournal/updateTeachingJournal'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 教学辅助日志添加
export const queryTeachingJournal = params => {
  return http({
    url: http.adornUrl('teachingJournal/queryTeachingJournal'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 教学评价查询
export const queryTeacherClassReport = params => {
  return http({
    url: http.adornUrl('teacherClassReport/queryTeacherClassReport'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 教学评价
// 课程信息列表
export const getCourseInfoList = params => {
  return http({
    url: http.adornUrl('teachevaluate/getCourseInfoList'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 课程详细信息
export const getCourseDetailInfo = params => {
  return http({
    url: http.adornUrl('teachevaluate/getCourseDetailInfo'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 获取课程下学生列表，参数courseId，数字
export const getCourseStudentList = params => {
  return http({
    url: http.adornUrl('answers/queryUserIdsByCourseId'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 保存评论信息
export const saveCommentInfo = params => {
  return http({
    url: http.adornUrl('teachevaluate/saveCommentInfo'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 删除评论信息
export const deleteCommentInfo = params => {
  return http({
    url: http.adornUrl('teachevaluate/delCommentInfo') + '?discussId=' + params,
    method: 'post'
    // data: http.adornData(params)
  })
}

// 评论置顶savePlaceTopCommentStatus
export const savePlaceTopCommentStatus = params => {
  return http({
    url: http.adornUrl('teachevaluate/savePlaceTopCommentStatus'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 保存评分
export const saveEvaluationContent = params => {
  return http({
    url: http.adornUrl('teachevaluate/saveEvaluationContent'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 柱状图
export const queryAnnualStatement = params => {
  return http({
    url: http.adornUrl('teacherClassReport/queryAnnualStatement'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 饼状图
export const queryCourseEvaluation = params => {
  return http({
    url: http.adornUrl('teacherClassReport/queryCourseEvaluation'),
    method: 'post',
    data: http.adornData(params)
  })
}

// 首页

export const getCourseInfoByCourseStatus = num => {
  return http({
    url: http.adornUrl(
      'homepageinfo/getCourseInfoByCourseStatusAndCourseType?courseType=' + num
    ),
    method: 'get'
  })
}

// 视频点击增加次数
export const updatePlayTimes = params => {
  return http({
    url: http.adornUrl('resourcesDemand/updatePlayTimes?videoId=') + params,
    method: 'post'
    // data: http.adornData(params)
  })
}

// 成果管理

export const queryMyClass = params => {
  return http({
    url: http.adornUrl('teachingJournal/queryMyClass'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 课程管理
export const queryCourse = params => {
  return http({
    url: http.adornUrl('queryCourse/queryCourse'),
    method: 'post',
    data: http.adornData(params)
  })
}
// 视频点播
export const queryResourcesDemand = params => {
  return http({
    url: http.adornUrl('resourcesDemand/queryResourcesDemand'),
    method: 'post',
    data: http.adornData(params)
  })
}


